package api

import (
	"github.com/gin-gonic/gin"
	"red/api/handler"
)

func LoadRouter(c *gin.Engine) {
	api := c.Group("/api")
	{
		user := api.Group("/user")
		{
			user.GET("/login", handler.Login)
			user.POST("/sendsms", handler.SendSms)
			user.POST("/show", handler.UserShow)
		}

		video := api.Group("/video")
		{
			video.GET("/list", handler.List)
			video.POST("/show", handler.Show)
			video.POST("/comment", handler.Comment)
		}

	}
}
